<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>AtkAction</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.73.2">
<link rel="start" href="index.html" title="ATK - Accessibility Toolkit">
<link rel="up" href="atk.html" title="ATK Library">
<link rel="prev" href="atk.html" title="ATK Library">
<link rel="next" href="AtkComponent.html" title="AtkComponent">
<meta name="generator" content="GTK-Doc V1.10 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
<link rel="chapter" href="atk.html" title="ATK Library">
<link rel="index" href="ix01.html" title="Index">
<link rel="index" href="ix02.html" title="Index of deprecated symbols">
<link rel="index" href="ix03.html" title="Index of new symbols in ATK 1.3">
<link rel="index" href="ix04.html" title="Index of new symbols in ATK 1.4">
<link rel="index" href="ix05.html" title="Index of new symbols in ATK 1.6">
<link rel="index" href="ix06.html" title="Index of new symbols in ATK 1.9">
<link rel="index" href="ix07.html" title="Index of new symbols in ATK 1.12">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
<tr valign="middle">
<td><a accesskey="p" href="atk.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
<td><a accesskey="u" href="atk.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
<th width="100%" align="center">ATK - Accessibility Toolkit</th>
<td><a accesskey="n" href="AtkComponent.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
</tr>
<tr><td colspan="5" class="shortcuts"><nobr><a href="#AtkAction.synopsis" class="shortcut">Top</a>
                   | 
                  <a href="#AtkAction.description" class="shortcut">Description</a>
                   | 
                  <a href="#AtkAction.object-hierarchy" class="shortcut">Object Hierarchy</a>
                   | 
                  <a href="#AtkAction.implementations" class="shortcut">Known Implementations</a></nobr></td></tr>
</table>
<div class="refentry" lang="en">
<a name="AtkAction"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="AtkAction.top_of_page"></a>AtkAction</span></h2>
<p>AtkAction — The ATK interface provided by UI components which the user can
activate/interact with,</p>
</td>
<td valign="top" align="right"></td>
</tr></table></div>
<div class="refsynopsisdiv">
<a name="AtkAction.synopsis"></a><h2>Synopsis</h2>
<pre class="synopsis">
                    <a class="link" href="AtkAction.html#AtkAction-struct" title="AtkAction">AtkAction</a>;
<a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"
>gboolean</a>            <a class="link" href="AtkAction.html#atk-action-do-action" title="atk_action_do_action ()">atk_action_do_action</a>                (<a class="link" href="AtkAction.html" title="AtkAction">AtkAction</a> *action,
                                                         <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"
>gint</a> i);
<a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"
>gint</a>                <a class="link" href="AtkAction.html#atk-action-get-n-actions" title="atk_action_get_n_actions ()">atk_action_get_n_actions</a>            (<a class="link" href="AtkAction.html" title="AtkAction">AtkAction</a> *action);
const <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"
>gchar</a>*        <a class="link" href="AtkAction.html#atk-action-get-description" title="atk_action_get_description ()">atk_action_get_description</a>          (<a class="link" href="AtkAction.html" title="AtkAction">AtkAction</a> *action,
                                                         <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"
>gint</a> i);
const <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"
>gchar</a>*        <a class="link" href="AtkAction.html#atk-action-get-name" title="atk_action_get_name ()">atk_action_get_name</a>                 (<a class="link" href="AtkAction.html" title="AtkAction">AtkAction</a> *action,
                                                         <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"
>gint</a> i);
const <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"
>gchar</a>*        <a class="link" href="AtkAction.html#atk-action-get-localized-name" title="atk_action_get_localized_name ()">atk_action_get_localized_name</a>       (<a class="link" href="AtkAction.html" title="AtkAction">AtkAction</a> *action,
                                                         <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"
>gint</a> i);
const <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"
>gchar</a>*        <a class="link" href="AtkAction.html#atk-action-get-keybinding" title="atk_action_get_keybinding ()">atk_action_get_keybinding</a>           (<a class="link" href="AtkAction.html" title="AtkAction">AtkAction</a> *action,
                                                         <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"
>gint</a> i);
<a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"
>gboolean</a>            <a class="link" href="AtkAction.html#atk-action-set-description" title="atk_action_set_description ()">atk_action_set_description</a>          (<a class="link" href="AtkAction.html" title="AtkAction">AtkAction</a> *action,
                                                         <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"
>gint</a> i,
                                                         const <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"
>gchar</a> *desc);
</pre>
</div>
<div class="refsect1" lang="en">
<a name="AtkAction.object-hierarchy"></a><h2>Object Hierarchy</h2>
<pre class="synopsis">
  GInterface
   +----AtkAction
</pre>
</div>
<div class="refsect1" lang="en">
<a name="AtkAction.implementations"></a><h2>Known Implementations</h2>
<p>
AtkAction is implemented by
 <a class="link" href="AtkHyperlink.html" title="AtkHyperlink">AtkHyperlink</a> and  <a class="link" href="AtkNoOpObject.html" title="AtkNoOpObject">AtkNoOpObject</a>.</p>
</div>
<div class="refsect1" lang="en">
<a name="AtkAction.description"></a><h2>Description</h2>
<p>
<a class="link" href="AtkAction.html" title="AtkAction"><span class="type">AtkAction</span></a> should be implemented by instances of <a class="link" href="AtkObject.html" title="AtkObject"><span class="type">AtkObject</span></a> classes with
which the user can interact directly, i.e. buttons, checkboxes,
scrollbars,  e.g. components which are not "passive"
providers of UI information.
</p>
<p>
Exceptions: when the user interaction is already covered by
another appropriate interface such as <a class="link" href="AtkEditableText.html" title="AtkEditableText"><span class="type">AtkEditableText</span></a> (insert/delete
test, etc.) or <a class="link" href="AtkValue.html" title="AtkValue"><span class="type">AtkValue</span></a> (set value) then these actions should not be
exposed by <a class="link" href="AtkAction.html" title="AtkAction"><span class="type">AtkAction</span></a> as well.  
</p>
<p>
Also note that the <a class="link" href="AtkAction.html" title="AtkAction"><span class="type">AtkAction</span></a> API is limited in that parameters may not
be passed to the object being activated; thus the action must be
self-contained and specifiable via only a single "verb".  Concrete
examples include "press", "release", "click" for buttons, "drag"
(meaning initiate drag) and "drop" for drag sources and drop targets,
etc.  
</p>
<p>
Though most UI interactions on components should be invocable via
keyboard as well as mouse, there will generally be a close mapping
between "mouse actions" that are possible on a component and the
AtkActions.  Where mouse and keyboard actions are redundant in effect,
<a class="link" href="AtkAction.html" title="AtkAction"><span class="type">AtkAction</span></a> should expose only one action rather than exposing redundant
actions if possible.  By convention we have been using "mouse centric"
terminology for <a class="link" href="AtkAction.html" title="AtkAction"><span class="type">AtkAction</span></a> names.
</p>
</div>
<div class="refsect1" lang="en">
<a name="AtkAction.details"></a><h2>Details</h2>
<div class="refsect2" lang="en">
<a name="AtkAction-struct"></a><h3>AtkAction</h3>
<pre class="programlisting">typedef struct _AtkAction AtkAction;</pre>
<p>
The AtkAction structure does not contain any fields.
</p>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="atk-action-do-action"></a><h3>atk_action_do_action ()</h3>
<pre class="programlisting"><a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"
>gboolean</a>            atk_action_do_action                (<a class="link" href="AtkAction.html" title="AtkAction">AtkAction</a> *action,
                                                         <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"
>gint</a> i);</pre>
<p>
Perform the specified action on the object.</p>
<p>

</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>action</code></em> :</span></p></td>
<td> a <a
href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject"
><span class="type">GObject</span></a> instance that implements AtkActionIface
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>i</code></em> :</span></p></td>
<td> the action index corresponding to the action to be performed 
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> <a
href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#TRUE:CAPS"
><code class="literal">TRUE</code></a> if success, <a
href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#FALSE:CAPS"
><code class="literal">FALSE</code></a> otherwise

</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="atk-action-get-n-actions"></a><h3>atk_action_get_n_actions ()</h3>
<pre class="programlisting"><a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"
>gint</a>                atk_action_get_n_actions            (<a class="link" href="AtkAction.html" title="AtkAction">AtkAction</a> *action);</pre>
<p>
Gets the number of accessible actions available on the object.
If there are more than one, the first one is considered the
"default" action of the object.</p>
<p>

</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>action</code></em> :</span></p></td>
<td> a <a
href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject"
><span class="type">GObject</span></a> instance that implements AtkActionIface
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> a the number of actions, or 0 if <em class="parameter"><code>action</code></em> does not
implement this interface.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="atk-action-get-description"></a><h3>atk_action_get_description ()</h3>
<pre class="programlisting">const <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"
>gchar</a>*        atk_action_get_description          (<a class="link" href="AtkAction.html" title="AtkAction">AtkAction</a> *action,
                                                         <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"
>gint</a> i);</pre>
<p>
Returns a description of the specified action of the object.</p>
<p>

</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>action</code></em> :</span></p></td>
<td> a <a
href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject"
><span class="type">GObject</span></a> instance that implements AtkActionIface
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>i</code></em> :</span></p></td>
<td> the action index corresponding to the action to be performed 
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>a description string, or <a
href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"
><code class="literal">NULL</code></a>
if <em class="parameter"><code>action</code></em> does not implement this interface.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="atk-action-get-name"></a><h3>atk_action_get_name ()</h3>
<pre class="programlisting">const <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"
>gchar</a>*        atk_action_get_name                 (<a class="link" href="AtkAction.html" title="AtkAction">AtkAction</a> *action,
                                                         <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"
>gint</a> i);</pre>
<p>
Returns a non-localized string naming the specified action of the 
object. This name is generally not descriptive of the end result 
of the action, but instead names the 'interaction type' which the 
object supports. By convention, the above strings should be used to 
represent the actions which correspond to the common point-and-click 
interaction techniques of the same name: i.e. 
"click", "press", "release", "drag", "drop", "popup", etc.
The "popup" action should be used to pop up a context menu for the 
object, if one exists.
</p>
<p>
For technical reasons, some toolkits cannot guarantee that the 
reported action is actually 'bound' to a nontrivial user event;
i.e. the result of some actions via <a class="link" href="AtkAction.html#atk-action-do-action" title="atk_action_do_action ()"><code class="function">atk_action_do_action()</code></a> may be
NIL.</p>
<p>

</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>action</code></em> :</span></p></td>
<td> a <a
href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject"
><span class="type">GObject</span></a> instance that implements AtkActionIface
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>i</code></em> :</span></p></td>
<td> the action index corresponding to the action to be performed 
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>a name string, or <a
href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"
><code class="literal">NULL</code></a>
if <em class="parameter"><code>action</code></em> does not implement this interface.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="atk-action-get-localized-name"></a><h3>atk_action_get_localized_name ()</h3>
<pre class="programlisting">const <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"
>gchar</a>*        atk_action_get_localized_name       (<a class="link" href="AtkAction.html" title="AtkAction">AtkAction</a> *action,
                                                         <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"
>gint</a> i);</pre>
<p>
Returns the localized name of the specified action of the object.</p>
<p>

</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>action</code></em> :</span></p></td>
<td> a <a
href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject"
><span class="type">GObject</span></a> instance that implements AtkActionIface
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>i</code></em> :</span></p></td>
<td> the action index corresponding to the action to be performed 
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>a name string, or <a
href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"
><code class="literal">NULL</code></a>
if <em class="parameter"><code>action</code></em> does not implement this interface.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="atk-action-get-keybinding"></a><h3>atk_action_get_keybinding ()</h3>
<pre class="programlisting">const <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"
>gchar</a>*        atk_action_get_keybinding           (<a class="link" href="AtkAction.html" title="AtkAction">AtkAction</a> *action,
                                                         <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"
>gint</a> i);</pre>
<p>
Returns a keybinding associated with this action, if one exists.
The returned string is in the format "&lt;a&gt;;&lt;b&gt;;&lt;c&gt;"
(i.e. semicolon-delimited), where &lt;a&gt; is the keybinding which
activates the object if it is presently enabled onscreen, 
&lt;b&gt; corresponds to the keybinding or sequence of keys
which invokes the action even if the relevant element is not
currently posted on screen (for instance, for a menu item it
posts the parent menus before invoking).  The last token in the
above string, if non-empty, represents a keyboard shortcut which
invokes the same action without posting the component or its
enclosing menus or dialogs.</p>
<p>

</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>action</code></em> :</span></p></td>
<td> a <a
href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject"
><span class="type">GObject</span></a> instance that implements AtkActionIface
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>i</code></em> :</span></p></td>
<td> the action index corresponding to the action to be performed 
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>a string representing the available keybindings, or <a
href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"
><code class="literal">NULL</code></a>
if there is no keybinding for this action.

</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="atk-action-set-description"></a><h3>atk_action_set_description ()</h3>
<pre class="programlisting"><a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"
>gboolean</a>            atk_action_set_description          (<a class="link" href="AtkAction.html" title="AtkAction">AtkAction</a> *action,
                                                         <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"
>gint</a> i,
                                                         const <a
href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"
>gchar</a> *desc);</pre>
<p>
Sets a description of the specified action of the object.</p>
<p>

</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>action</code></em> :</span></p></td>
<td> a <a
href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject"
><span class="type">GObject</span></a> instance that implements AtkActionIface
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>i</code></em> :</span></p></td>
<td> the action index corresponding to the action to be performed 
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>desc</code></em> :</span></p></td>
<td> the description to be assigned to this action
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> a gboolean representing if the description was successfully set;
</td>
</tr>
</tbody>
</table></div>
</div>
</div>
</div>
<div class="footer">
<hr>
          Generated by GTK-Doc V1.10</div>
</body>
</html>
